/**
 * 对象比较
 * 对象浅层比较（仅一级属性）
 */
export const objShallowEqual = (obj1: Record<any, any>, obj2: Record<any, any>) => {
	const keys1 = Object.keys(obj1),
		keys2 = Object.keys(obj2);
	if (keys1.length !== keys2.length) return false;
	return keys1.every((key) => obj1[key] === obj2[key]);
};
